package com.demo.annotation.domain;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class User
{
    //实体类中，Integer类型的属性加@ApiModelProperty时，必须要给example参数赋值，且值必须为数字类型。
    @NotNull
    private Integer id;
    @NotNull
    private String userName;
    @NotNull
    private String password;
    @NotNull
    private String number;

    //getter/setter用@Data注解自动生成
}